
<div id="modal-anexar-doc<?php echo $this->emprestimo->id?>" class="modal hide fade" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
        <h3 id="myModalLabel">
            Anexar Documento - Empréstimo #<?php echo $this->emprestimo->id?>
        </h3>
    </div>
    <div class="modal-body">

        <form action="<?php echo $this->baseUrl() ?>/emprestimo/anexar" method="post" enctype="multipart/form-data" class="form-horizontal forms" role="form">
            <div class="form-group">
                <div class="col-sm-10">
                    <div class="input-prepend input-append">
                        <input type="hidden" class="form-control" name="Emprestimo_id" value="<?php echo $this->emprestimo->id ?>" required>
                        <input type="hidden" class="form-control" name="Emprestimo_Cliente_id" value="<?php echo $this->emprestimo->Cliente_id ?>" required>
                        <input type="hidden" class="form-control" name="Banco_id" value="<?php echo $this->emprestimo->Banco_id ?>" required>
                        <input type="hidden" class="form-control" name="Filial_id" value="<?php echo $this->emprestimo->Filial_id ?>" required>
                        <input type="file" class="form-control" name="arquivo" placeholder="Selecione o arquivo" maxlength="80" title="Selecione o arquivo" data-placement="bottom" required>
                    </div>
                </div>
            </div>
            
            <div class="form-group">
                <div class="col-sm-10">
                    <div class="input-prepend input-append">
                        <span class="add-on"><i class="icon-asterisk"></i></span> 
                        <select name="parcela" title="Selecione a parcela em que deseja anexar o arquivo">
                            <?php for ($i = 1 ; $i <= $this->emprestimo->parcelas ; $i++): ?>
                                <option value="<?php echo $i ?>"><?php echo $i ?></option>
                            <?php endfor; ?>
                        </select>
                    </div>
                </div>
            </div>   
            
            <div class="form-group">
                <div class="col-sm-offset-2 col-sm-10 btns-form">
                    <button type="submit" class="btn btn-large btn-primary">Salvar</button>
                    <button type="reset" class="btn btn-large btn-default">Limpar</button>
                </div>
            </div>
        </form>
    </div>
    <div class="modal-footer">
        <button class="btn" data-dismiss="modal" aria-hidden="true">Fechar</button>
    </div>
</div>


